package org.mics.cyy.backUser.request;

import java.io.Serializable;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.Size;

import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
import lombok.EqualsAndHashCode;

/**
 * 增加/修改角色请求
 * @author mics
 * @date 2023-10-9
 * @version  1.0
 */
@Data
@EqualsAndHashCode(callSuper = false)
@Schema(description = "增加/修改角色请求")
public class RoleRequest implements Serializable {
	/**
	 * 序列号 
	 */
	private static final long serialVersionUID = -3568441302171682553L;
	
	@Schema(description = "菜单id，新增不传修改传")
	private String id;
	
	@Schema(description = "角色名称",required = true)
	@NotBlank(message = "角色名称不能为空")
	@Size(min = 2,max=32,message = "角色名称长度2-32位")
	private String name; 
	 
	@Schema(description = "角色编码",required = true)
	@NotBlank(message = "角色编码不能为空")
	@Size(min = 2,max = 32,message = "角色编码长度2-32位")
	 private String code; 
}
